﻿<UserControl xmlns:PageBar="clr-namespace:Mengsk.ProxyDelivery.App.UI.PageBar"  x:Class="Mengsk.ProxyDelivery.App.UI.Accounting.SellerChargeUserControl"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             d:DesignHeight="300" d:DesignWidth="1000" Loaded="UserControl_Loaded">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition Height="*"/>
            <RowDefinition Height="Auto"/>
        </Grid.RowDefinitions>

        <StackPanel Orientation="Horizontal" >
            <TextBlock Text="支付平台:" Margin="3" VerticalAlignment="Center"/>
            <ComboBox Name="cbbPayTypes" Margin="3" VerticalAlignment="Center" Width="100">

            </ComboBox>
            <TextBlock Text="卖家编号:" Margin="3" VerticalAlignment="Center"/>
            <TextBox Name="tbSellerId" Margin="3" VerticalAlignment="Center" Width="100"/>
            <TextBlock Text="交易流水号:" Margin="3" VerticalAlignment="Center"/>
            <TextBox Name="tbComment" Margin="3" VerticalAlignment="Center" Width="100"/>
            <TextBlock Text="开始时间" Margin="3" VerticalAlignment="Center"/>
            <DatePicker Name="dpStart" Margin="3" VerticalAlignment="Center" Width="130"/>
            <TextBlock Text="结束时间" Margin="3" VerticalAlignment="Center"/>
            <DatePicker Name="dpEnd" Margin="3" VerticalAlignment="Center" Width="130"/>
            <Button Name="btnSearch" Content="查询" Margin="3" VerticalAlignment="Center" Click="btnSearch_Click" Width="60"/>
        </StackPanel>

        <DataGrid Grid.Row="1" Name="dgvSelelrCharges" AutoGenerateColumns="False" GridLinesVisibility="All" IsReadOnly="True">
            <DataGrid.Columns>
                <DataGridTextColumn Header="充值编号" Binding="{Binding Id}"/>
                <DataGridTextColumn Header="卖家编号" Binding="{Binding SellerId}"/>
                <DataGridTextColumn Header="充值方式" Binding="{Binding Online,Converter={StaticResource intConverter},ConverterParameter=转账充值|在线支付}"/>
                <DataGridTextColumn Header="支付方式" Binding="{Binding PayType,Converter={StaticResource descriptionConverter}}"/>
                <DataGridTextColumn Header="支付账户" Binding="{Binding PayAccount}"/>
                <DataGridTextColumn Header="支付金额" Binding="{Binding Money}"/>
                <DataGridTextColumn Header="描述" Binding="{Binding Comment}"/>
                <DataGridTextColumn Header="创建时间" Binding="{Binding CreateTime,StringFormat=yyyy-MM-dd HH:mm:ss}"/>
                <DataGridTextColumn Header="状态" Binding="{Binding State,Converter={StaticResource descriptionConverter}}"/>
            </DataGrid.Columns>
        </DataGrid>
        <PageBar:PageBarUserControl Grid.Row="2" x:Name="pbBar" PageSize="200" PageChanging="PageBarUserControl_PageChanging" />
    </Grid>
</UserControl>
